Apple IIc: Serial port interfacing (1 of 2)


 
This article last reviewed: 21 April 1988
 
The Apple IIc serial ports are 5-pin DIN connectors.  Both Port 1 (Printer)
and Port 2 (Modem) have the same pin-out and signal description.  Here are
the cable descriptions for connecting them to the Imagewriter and the Apple
Modem.
 
  Apple IIc Serial Port   -  Imagewriter   -  Apple Modem
 
         DTR (1)              6 - DSR         6 - DTR
         TXD (2)              3 - RCD         9 - TXD
         GND (3)              7 - GND         3 - GND
         RCD (4)              2 - TXD         5 - RCD
         DSR (5)             20 - DTR         2 - DSR
 
                                               __
            _ _____                           l  ]
           l_l      \                         l  ]
      (5)       (1)  \ _____________________ /   ]
                      )_____________________)    ]
      (4)       (2)  /                       \   ]
           (3)______/                         l  ]
                                              l__]
          DIN type connector         DB type connector
 
Setting up the printer port from within a program on the IIc is essentially
the same as changing the settings on previous interface cards:  after first
directing output to the serial port (using PR#1 and PR#2 for Ports 1 and 2,
respectively), the commands can then be sent to the serial port.  Each
command for Port 1 must be preceded by CTRL-I.  The commands for Port 1 are:
 
Cmd    Description
 
 nnn   Set line width( from 001 through 255): This command must
       be followed by an 'N' or a <CR>.
 
 nnB   Set baud rate to value corresponding to nn.
 
       nn   Rate                 nn   Rate
 
       01 - 50                   09 - 1800
       02 - 75                   10 - 2400
       03 - 110                  11 - 3600
       04 - 135                  12 - 4800
       05 - 150                  13 - 7200
       06 - 300                  14 - 9600
       07 - 600                  15 - 19200
       08 - 1200
 
 nB    Set Data Format to values corresponding to n.
 
       n  -  Format
 
       0     8 data 1 stop
       1     7 data 1 stop
       2     6 data 1 stop
       3     5 data 1 stop
       4     8 data 2 stop
       5     7 data 2 stop
       6     6 data 2 stop
       7     5 data 2 stop
 
 I     Echo output to screen.
 
 K     Disable <LF> after <CR>.
 
 L     Generate <LF> after <CR>.
 
 nP    Set Parity corresponding to n.
 
       n  -  Parity
 
       0     none
       1     odd
       2     none
       3     even
       4     none
       5     mark (1)
       6     none
       7     space (0)
 
 R     Reset Port 1 and exit from serial port 1 firmware.
 
 S     Send a 233 millisecond Break character
 
 Z     Zap (ignore) further command characters (until
       CTRL-Reset or PR#1).  Do not format output or insert
       carriage returns into output stream.
